<template>
  <div>
    <p>
      房间号： <input type="text" v-model="chat">
    </p>
    <p>
      <button @click="join_chat">进入</button>
    </p>
  </div>
</template>

<script>
export default {
  name:"Index",
  data(){
    return{
      mid: this.$route.query.mid,
      uid: this.$route.query.uid,
      mer_name: this.$route.query.mer_name,
      por_img: this.$route.query.por_img,
      mer_img: this.$route.query.mer_img,
      chat: null,
    }
  },
  mounted(){
  },
  methods:{
    join_chat(){
     this.$router.push({path:"/message",query:{chat_id: this.chat,mid:this.mid,uid:this.uid,
     mer_name:this.mer_name,por_img:this.por_img,
     mer_img:this.mer_img}})
    },
  }
}
</script>

<style>
.search{
  margin: 0px auto;
  width: 300px;
}
</style>